#pragma once

#include <Engine.hpp>
#include <Actions.hpp>
//
//
//
class TState : public TObject
{
public:
	struct StateUpdate
	{
		enum Enum
		{
			Prev,
			Stay,
			Next,
			Exit,
		};
	};

	virtual void Activate(Engine&/* engine*/)
	{
	}

	virtual void Deactivate(Engine&/* engine*/)
	{
	}

	virtual void OnAction(const Action&/* evnt*/)
	{
	}

	virtual StateUpdate::Enum Update(Engine&/* engine*/, float /*dt*/)
	{
		return mStateMode;
	}
public:
	TState() : mStateMode(StateUpdate::Stay)
	{
	}
protected:
	StateUpdate::Enum mStateMode;
};

typedef ref<TState> State;